Test Series - computer fundamental

Test Number 16/95

Q: _______________ is a straightforward method of representing positive and negative numbers.
A. Radix
B. Complement
C. Sign Magnitude
D. Encode
Solution: Sign Magnitude is used for the representation of positive and negative numbers. If the leftmost digit is 0, the number is positive. If the leftmost digit is 1, the number is negative.
Q: The additive inverse of a number is the number which when added to the original number gives 1 as a result.
A. True
B. False
C. none
D. 0
Solution: Additive Inverse of a number is the number which gives 0 and not 1 when added to the original number. e.g. number=45, additive inverse =-45, after addition they give 0.
Q: The 1’s complement of 1 in 4 bits is __________
A. 0001
B. 0
C. 1001
D. 1110
Solution: 1’s complement is obtained by reversing the bits from 0 to 1 and vice-versa. Binary of 1 is : 0001 and 1’s complement is : 1110.
Q: The binary number 111 in its 2’s complement form is ____________
A. 010
B. 001
C. 000
D. 111
Solution: 2’s complement is obtained by adding 1 to the 1’s complement. 1’s complement of 111: 000 and 2’s complement:001.
Q: The sign magnitude representation of -9 is ___________
A. 00001001
B. 11111001
C. 10001001
D. 11001
Solution: In case of a negative number, the leftmost digit is 1 if the number is negative. Therefore, +9=00001001 and -9=10001001. Similarly for all other negative numbers.
Q: If you are given a word of size n bits, the range of 2’s complement of binary numbers is _______
A. -2n+1 to +2n+1
B. -2n-1 to +2n-1
C. -2n-1 to +2n+1
D. -2n-1 to +2n-1-1
Solution: 2’s complement is obtained by adding 1 to the 1’s complement. For e.g. 5 :0101 and 1’s complement=1010 and 2’s complement=1011.
Q: In both signed magnitude and 2’s complement , positive and negative numbers are separated using ____________
A. LSB
B. MSB
C. 0
D. 1
Solution: The positive and negative numbers are separated using the MSB. MSB is the Most Significant Bit. MSB is the leftmost bit. e.g. If 1000 is the number then 1 is the most significant bit.
Q: Single Precision format comprises of _________ bits.
A. 4
B. 8
C. 16
D. 32
Solution: The single precision format comprises of 32-bits. It has 1 sign bit, 8 bits for exponent and 23 for the mantissa.
Q: If m is the 2’s complement and n is the binary number, then ______________
A. m=n’
B. m=n’+1
C. m=n’-1
D. m=n
Solution: 2’s complement is simply obtained by addition of 1. So if n is the number and we take the 2’s complement, add 1 to it, we get the 2’s complement. Therefore, m=n’+1.
Q: The possible number of bit patterns with 8 bits ________________
A. 128
B. 8
C. 24
D. 256
Solution: The total number of patterns that can be formed using n-bits are 2n. Here, possible patterns are: 28=256.

You Have Score    /10